package framework;

public class UtilityUnit {
	public static Double toDouble(String valueText) {
		String s = valueText.replace("km", "");
		return Double.valueOf(s);
	}

	public static Double[] lesserData(Double[] data, Integer length) {
		Double[] ret = new Double[length];
		double step = (double)data.length / (double)length;
		for (int i = 0; i < length; i++) {
			ret[i] = data[(int)(i*step)];
		}
		return ret;
	}
}
